Create a results dashboard#

[1]:
# import libraries
import jax.numpy as jnp
from optymus import Optimizer
from optymus.benchmark import MccormickFunction

[2]:
# define the objective function
f = MccormickFunction()

# define the initial point
initial_point = jnp.array([5.0, 8.0])
[3]:
# instantiate the optimizer with the objective function and the initial point
# select the method to be used
opt = Optimizer(f_obj=f,
                x0=initial_point,
                method='gradient_descent',
                )
Gradient Descent 0:   8%|▊         | 8/100 [00:00<00:05, 16.33it/s]
[4]:
opt.plot_results(show=True, notebook=True)
[5]:
opt.create_dashboard(port=8052)